package day10;

import java.util.ArrayList;

import org.junit.Test;

public class ArrayUtilTest {
	public static void main(String[] args) {
		int []array = {35,55,4,248,44,88};
		int max = ArrayUtil.max(array);
		System.out.println(max);
		ArrayUtil.bubbleSort(array);
		for(int i = 0; i < array.length; i++) {
			System.out.print(array[i] + " ");
		}
	}
	
	@Test
	public void test(){
		int []array = new int[3];
		ArrayList<Integer> list = new ArrayList<>();
		list.add(2);
		list.add(20);
		for (Integer integer : list) {
			System.out.println(integer + " ");
		}
		System.out.println();
		System.out.println(Integer.MAX_VALUE);
		Integer integer = 4;
		int i = integer.intValue();
		integer = integer + 2;
		System.out.println(integer);
	}
	
	@Test
	public void test2(){
		String str = 12 + " ";
		String str1 = Integer.toString(3);
		String str2 = Double.toString(3.14);
		System.out.println(str);
		System.out.println(str2);
		System.out.println(Integer.parseInt(str1));
		System.out.println("==================================");
		String str3 = "3.14";
		double d = Double.parseDouble(str3);
		System.out.println(d);
		
	}
}
